package com.zxl.designpattern.creator.prototype;

import java.io.Serializable;

/**
 * @author zxl
 * @version 1.0
 * @description 员工类
 * @date 2025/5/31 22:58
 */
public class Employee implements Cloneable, Serializable {

    private String empNO;
    private String name;
    private int age;
    public Employee() {
    }
    public Employee(String empNO, String name, int age) {
        this.empNO = empNO;
        this.name = name;
        this.age = age;
    }

    public String getEmpNO() {
        return empNO;
    }

    public void setEmpNO(String empNO) {
        this.empNO = empNO;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    @Override
    public String toString() {
        return "Employee=" + super.toString() + "{" +
                "empNO='" + empNO + '\'' +
                ", name='" + name + '\'' +
                ", age=" + age +
                '}';
    }

    public Employee clone() throws CloneNotSupportedException {
        return (Employee) super.clone();
    }
}
